<?php

class User
{
    static public function getPageName($group)
    {
        $pages = array(
            1 => 'home',
            2 => 'employment',
            3 => 'contact',
            4 => 'support',
            5 => 'aboutus',
            6 => 'service',
            7 => 'product',
            8 => 'faq'
        );

        return isset($pages[$group]) ? $pages[$group] : 0;
    }

    static public function getGroup($pageName)
    {
        $pages = array(
            'home' => 1,
            'employment' => 2,
            'contact' => 3,
            'support' => 4,
            'aboutus' => 5,
            'service' => 6,
            'product' => 7,
            'faq'     => 8
        );

        return isset($pages[$pageName]) ? $pages[$pageName] : 0;
    }
}